<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        // function foo() {
        //     console.log("1");
        //     return "hello";
        // }

        let a = 1;

        function foo() {
            console.log(a);
            a++;
            if (a >= 5) {
                return;
            }
            foo();
        }

        foo();

        // console.log(foo());

        // const data = foo();
        // console.log('data', data);


    </script>
</body>

</html>